home *** CD-ROM | disk | FTP | other *** search
- Path: symiserver2.symantec.com!usenet
- From: Kostya Vasilyev <kostya@scruznet.com>
- Newsgroups: comp.lang.smalltalk,comp.object,comp.lang.c++,comp.lang.java
- Subject: Re: The Good, the Bad, the Ugly, and the Wicked ...
- Date: Fri, 29 Mar 1996 08:36:11 -0800
- Organization: Dreaded Neurological Army (DNA)
- Message-ID: <315C117B.EF0@scruznet.com>
- References: <31570B8E.5A12@vmark.com> <31586721.1750@mobius.net> <4jbk0m$jt9@news4.digex.net> <AD7EDB45966858C12@mac-sandvik.engr.sgi.com>
- NNTP-Posting-Host: 155.64.35.90
- Mime-Version: 1.0
- Content-Type: text/plain; charset=us-ascii
- Content-Transfer-Encoding: 7bit
- X-Mailer: Mozilla 2.0 (Win95; I)
-
- Kent Sandvik wrote:
- >
- > In article <4jbk0m$jt9@news4.digex.net>,
- > ell@access1.digex.net (Ell) wrote:
- >
- > >C++ very much has dynamic binding; lookup virtual functions.
- >
- > It depends how you defined dynamic binding, could you send messages to
- > arbitrary methods in C++ during runtime (or java, by the way)?
- >
- > --Kent
-
- It's not "call by name" but in C++ you can use functors implemented with the help of
- templates. That does not have the restriction that that the client (the object being called
- back) be derived from a specific interface or class.
-
- In Java, on the other hand, the only way of doing this is to require that all objects that
- you want to call implement a particular interface -- but that may be inconvenient or
- restrictive in some cases. Of course, there is sysExt, but it's beauty nonwithstanding,
- this is still a hack and I'm not even sure if applets are allows to do this???
-
- -- Kostya V.
-